import connection from './connection'

export function queryAll(sql:string){
  return new Promise((resolve,reject)=>{
    connection.query(sql,(err:Error,res:object)=>{
      if(err){
        reject(err)
      }
      resolve(res)
    });
  });
}